<script language="javascript" type="text/javascript" src="js/common.js"></script>
<!-- List anh tu dong theo chieu cao -->
<script language="javascript" type="text/javascript" src="js/jquery.masonry.min.js"></script>
<script type="text/javascript">
    $(document).ready(function () {
        $('.ds_anh').masonry({
            itemSelector:'.box_items'
        });
        var hdoc = $(document).height() + 40;
        $('body').css('min-height', hdoc);
    });
</script>

<!-- Lightbox khi click vao hinh thumbnail-->
<script type="text/javascript" src="fancybox/jquery.fancybox-1.3.4.js"></script>
<link rel="stylesheet" type="text/css" href="fancybox/jquery.fancybox-1.3.4.css" media="screen"/>
<script type="text/javascript">
    $(document).ready(function () {
       
        $(".mercy_popup").fancybox({
            'titlePosition':'inside',
            'transitionIn':'none',
            'transitionOut':'none',
	    'height' : '1000px',              
            'onStart': function(){                              
                $('#wrap-container').show();
                $('body').css("overflow","hidden");
                $("#fancybox-overlay").css({"position":"fixed"});
                $("#wrapper-container").css({"overflow": "hidden"});
                $("#wrapper_footer").css({"display":'none'});
                $('body').css('height', $("#fancybox-wrap").height());
            },
            'onClosed': function(){
                $('#wrap-container').hide();
                $('body').css("overflow","auto");
                $("#wrapper-container").css({"overflow": "auto"});
                $("#wrapper_footer").css({"overflow": "auto", "position": ""});
                $("#wrapper_footer").css({"display":'block'});
            }
        });
    });
</script>
<div id="wrapper_category" class="bg_trang_cate">
    <div class="">

        <div class="cate_current">
            <?php if(isset($row_detail_cate_parent)){ ?>
                <a href="<?php echo $row_detail_cate_parent['cate_alias'];?>.html"><?php echo $row_detail_cate_parent['cate_name'];?></a> &curren; 
            <?php } ?>
                <a href="<?php echo $row_detail_cate['cate_alias'];?>.html"><?php echo $row_detail_cate['cate_name'];?></a>
            <p class="icon_arrow_down"></p>
        </div>

        <div class="contact_form list_category">
            <div id="ds_sanpham">
                <div class="list_anh">
                    <div class="ds_anh">
                        <?php while($row = mysql_fetch_assoc($rs_product)){?>
                        <div class="box_items">
                            <div class="bg_border">
                                <div class="pics">
                                    <p><a class="mercy_popup" href="ajax/getdetail.php?product_id=<?php echo $row['product_id']; ?>" data-component-value="<?php echo $row['product_id']; ?>">
                                            <img src="<?php echo str_replace("../upload", "upload/r",$row['url_images'])?>" align="absmiddle"/></a></p>
                                    <p class="txt_12"><?php echo $row['description'];?></p>
                                    <p class="danhmuc">Danh mục: <a href="#"><?php echo $row_detail_cate['cate_name'];?></a></p>
                                    <div class="txt_11 price">
                                        <p><span>Giá tham khảo 
                                                <?php if($row['price']!=''){?>
                                                <b><?php echo number_format($row['price'], 0, ',', '.');?></b> VNĐ
                                                <?php } else{ ?>
                                                <b>Liên hệ</b>
                                                <?php }?>
                                            </span></p>
                                    </div>
                                    <p class="thamkhaothem">Xem thêm: <a target="_blank" href="#">http://www.mercy.vn/nhat-ki</a></p>
                                    <p class="right"><a title="share facebook" href="#"><img src="css/images/icons/facebook.gif" align="absmiddle" /></a></p>
                                </div>
                                <div class="clear">&nbsp;</div>
                            </div>
                        </div>
                        <?php } ?>
                    </div>
                    <!--
                    <div class="phantrang">
                        <ul>
                            <li><a class="active" href="#">1</a></li>
                            <li><a href="#">2</a></li>
                            <li><a href="#">3</a></li>
                            <li><a href="#">4</a></li>
                            <li><a href="#">5</a></li>
                            <li><a href="#">...</a></li>
                            <li><a href="#">11</a></li>
                            <li><a href="#">12</a></li>
                        </ul>
                    </div>
                    -->

                </div>
            </div>
        </div>
    </div>
</div>